home *** CD-ROM | disk | FTP | other *** search
/ Aminet 38 / Aminet 38 (2000)(Schatztruhe)[!][Aug 2000].iso / Aminet / util / batch / MUIRequestStr.lha / MUIRequestString / MUIRequestString.install < prev    next >
Encoding:
Text File  |  2000-05-17  |  8.4 KB  |  333 lines

  1. ; $VER: Installation script for MUIRequestString 0.4 (14.05.00)
  2. ; © 2000 Jean Holzammer
  3. ; Created with GoldED 6.16
  4.  
  5. (if (= @language "Deutsch")
  6.  
  7.             (
  8.  
  9.                (set #osversion_msg                    "Falsche Betriebssystemversion (Software benötigt OS 39 oder besser) !")
  10.  
  11.                (set #onerror_msg                      "Während der Installation ist ein Fehler aufgetreten. Bitte Log-Datei überprüfen für ein besseres Verständnis des Fehlers.")
  12.  
  13.                (set #general_copyfiles_prompt         "Bitte zu kopierende Datei(en) auswählen...")
  14.  
  15.                (set #general_askbool_yes              "Ja")
  16.  
  17.                (set #general_askbool_no               "Nein")
  18.  
  19.                (set #executable_askdir_prompt         "Bitte Zielpfad für das Programm MUIRequestString wählen...")
  20.  
  21.                (set #executable_askdir_help           "Es wird empfohlen, ein Ziel zu wählen, das im Pfad liegt, am sinnvollsten C: .")
  22.  
  23.                (set #documentation_askbool_prompt     "Soll die AmigaGuide/PowerGuide Dokumentation installiert werden ?")
  24.  
  25.                (set #documentation_askbool_help       "Momentan ist nur eine englische Dokumentation verfügbar.")
  26.  
  27.                (set #documentation_askdir_prompt      "Bitte Zielpfad für die Dokumentation wählen...")
  28.  
  29.                (set #documentation_askdir_help        #documentation_askbool_help)
  30.  
  31.                (set #documentation_copyfiles_help     #documentation_askbool_help)
  32.  
  33.                (set #catalogs_askbool_prompt          "Sollen Katalog-Dateien installiert werden ?")
  34.  
  35.                (set #catalogs_askbool_help            "Momentan ist nur eine deutsche Lokalisation verfügbar.")
  36.  
  37.                (set #catalogs_askoptions_prompt       "Select the language(s) you'd like to install")
  38.  
  39.                (set #catalogs_askoptions_help         #catalogs_askbool_help)
  40.  
  41.                (set #german_catalog_askdir_prompt     "Bitte Zielpfad für den deutschen Katalog wählen...")
  42.  
  43.                (set #german_catalog_askdir_help       "Sollte in LOCALE:Catalogs/Deutsch sein.")
  44.  
  45.                (set #german_catalog_copyfiles_prompt  #catalogs_askbool_help)
  46.  
  47.                (set #translation_msg                  "Wer Interesse am Erzeugen einer Katalog-Datei für eine andere Sprache hat, kann MUIRequestString.ct als Ausgangsbasis verwenden oder mich kontakten.")
  48.  
  49.             )
  50.  
  51.             ; else use English version
  52.  
  53.             (
  54.  
  55.                (set #osversion_msg                    "Incorrect OS version (software requires OS 39 or better) !")
  56.  
  57.                (set #onerror_msg                      "An error has occurred during installation. Please check the log file to understand the error.")
  58.  
  59.                (set #general_copyfiles_prompt         "Select file(s) to be copied to...")
  60.  
  61.                (set #general_askbool_yes              "Yes")
  62.  
  63.                (set #general_askbool_no               "No")
  64.  
  65.                (set #executable_askdir_prompt         "Please choose the destination path for the MUIRequestString executable...")
  66.  
  67.                (set #executable_askdir_help           "It's recommended that you choose a destination that is in your path, most reasonably C: .")
  68.  
  69.                (set #documentation_askbool_prompt     "Would you like the AmigaGuide/PowerGuide documentation to be installed ?")
  70.  
  71.                (set #documentation_askbool_help       "Only English documentation available for now.")
  72.  
  73.                (set #documentation_askdir_prompt      "Please choose the destination path for the documentation...")
  74.  
  75.                (set #documentation_askdir_help        #documentation_askbool_help)
  76.  
  77.                (set #documentation_copyfiles_help     #documentation_askbool_help)
  78.  
  79.                (set #catalogs_askbool_prompt          "Would you like catalogs to be installed ?")
  80.  
  81.                (set #catalogs_askbool_help            "Only German localisation available for now.")
  82.  
  83.                (set #catalogs_askoptions_prompt       "Select the language(s) you'd like to install")
  84.  
  85.                (set #catalogs_askoptions_help         #catalogs_askbool_help)
  86.  
  87.                (set #german_catalog_askdir_prompt     "Please choose the destination path for the German catalog...")
  88.  
  89.                (set #german_catalog_askdir_help       "Should be in LOCALE:Catalogs/Deutsch.")
  90.  
  91.                (set #german_catalog_copyfiles_prompt  #catalogs_askbool_help)
  92.  
  93.                (set #translation_msg                  "If you are interested in creatung a catalog file for another language you can use MUIRequestString.ct as a basis or contact me.")
  94.  
  95.             )
  96.  
  97. )
  98.  
  99. ; check if we are running under correct OS
  100.  
  101. (if (< (/ (getversion) 65536) 39)
  102.  
  103.     (
  104.         (abort #osversion_msg)
  105.     )
  106. )
  107.  
  108. ; error handling
  109.  
  110. (onerror
  111.  
  112.     (if (> @ioerr 0)
  113.  
  114.         (
  115.             (message
  116.  
  117.                 (#onerror_msg)
  118.  
  119.                 (set @default-dest "")
  120.  
  121.             )
  122.         )
  123.     )
  124.  
  125.     (exit (quiet))
  126. )
  127.  
  128.  
  129.  
  130.  
  131.  
  132.     ; normal installation
  133.  
  134.     (
  135.         (welcome)
  136.  
  137.         ; --- insert your code below ---
  138.  
  139.         
  140.  
  141.  
  142.         (set @default-dest
  143.  
  144.             (askdir
  145.  
  146.                 (prompt #executable_askdir_prompt)
  147.  
  148.                 (help   #executable_askdir_help)
  149.  
  150.                 (default "C:")
  151.             )
  152.         )
  153.  
  154.         (copyfiles
  155.  
  156.             (prompt #general_copyfiles_prompt @default-dest)
  157.  
  158.             (help   "")
  159.  
  160.             (source "MUIRequestString")
  161.  
  162.             (dest @default-dest)
  163.  
  164.             (confirm)
  165.  
  166.             (optional "fail")
  167.         )
  168.  
  169.         (set #result
  170.  
  171.             (askbool
  172.  
  173.                 (prompt #documentation_askbool_prompt)
  174.  
  175.                 (help   #documentation_askbool_help)
  176.  
  177.                 (choices
  178.  
  179.                     #general_askbool_yes         ;1
  180.                     #general_askbool_no          ;0
  181.                 )
  182.  
  183.                 (default 1)
  184.             )
  185.         )
  186.         
  187.         (if (= #result 1)  ;Yes
  188.  
  189.             (
  190.                (set @default-dest
  191.  
  192.                   (askdir
  193.  
  194.                     (prompt #documentation_askdir_prompt)
  195.  
  196.                     (help   #documentation_askdir_help)
  197.  
  198.                     (default "HELP:English")
  199.  
  200.                   )
  201.  
  202.                )
  203.  
  204.                (copyfiles
  205.  
  206.                   (prompt #general_copyfiles_prompt @default-dest)
  207.  
  208.                   (help   #documentation_copyfiles_help)
  209.  
  210.                   (source "Docs/English")
  211.  
  212.                   (all)
  213.  
  214.                   (dest @default-dest)
  215.  
  216.                   (confirm)
  217.  
  218.                   (optional "fail")
  219.  
  220.                )
  221.  
  222.  
  223.  
  224.             )
  225.  
  226.         )
  227.  
  228.         (set #result
  229.  
  230.             (askbool
  231.  
  232.                 (prompt #catalogs_askbool_prompt)
  233.  
  234.                 (help   #catalogs_askbool_help)
  235.  
  236.                 (choices
  237.  
  238.                     "Yes" ;1
  239.                     "No"  ;0
  240.                 )
  241.  
  242.                 (default 1)
  243.             )
  244.         )
  245.  
  246.         (if (= #result 1) ;Yes
  247.  
  248.             (
  249.              (set #result
  250.  
  251.                  (askoptions
  252.  
  253.                      (prompt #catalogs_askoptions_prompt)
  254.  
  255.                      (help   #catalogs_askoptions_help)
  256.  
  257.                      (choices
  258.  
  259.                          "Deutsch"
  260.  
  261.                          ;"Zwei"
  262.  
  263.                          ;"Drei"
  264.  
  265.                      )
  266.  
  267.                      (default 0)
  268.                  )
  269.              )
  270.  
  271.              (set #firstchoice  (NOT (IN #result 0)))
  272.              ;(set #secondchoice (NOT (IN #result 1)))
  273.              ;(set #thirdchoice  (NOT (IN #result 2)))
  274.  
  275.              ;(if #firstchoice  then (message "Nr.1 selektiert !"))
  276.              ;(if #secondchoice then (message "Nr.2 selektiert !"))
  277.              ;(if #thirdchoice  then (message "Nr.3 selektiert !"))
  278.  
  279.              (if #firstchoice then  ; word ´then must be provided ! else error
  280.  
  281.                  (
  282.  
  283.                     (set @default-dest
  284.  
  285.                        (askdir
  286.  
  287.                           (prompt #german_catalog_askdir_prompt)
  288.  
  289.                           (help   #german_catalog_askdir_help)
  290.  
  291.                           (default "LOCALE:Catalogs/Deutsch")
  292.  
  293.                        )
  294.  
  295.                     )
  296.  
  297.                     (copyfiles
  298.  
  299.                        (prompt #general_copyfiles_prompt @default-dest)
  300.  
  301.                        (help   #german_catalog_copyfiles_help)
  302.  
  303.                        (source "Catalogs/Deutsch/MUIRequestString.catalog")
  304.  
  305.                        (dest @default-dest)
  306.  
  307.                        (confirm)
  308.  
  309.                        (optional "fail")
  310.  
  311.                     )
  312.  
  313.                  )
  314.  
  315.              )
  316.  
  317.  
  318.             )
  319.  
  320.         )
  321.  
  322.  
  323.         (set @default-dest "")
  324.  
  325.         (message #translation_msg)
  326.  
  327.         ; --- end of your code ---
  328.  
  329.         (exit)
  330.  
  331. )
  332.  
  333.